//Source file: D:\\JavaSE\\software-learning\\software-engineering\\work3\\Client.java


public class Client 
{
   
   /**
    * @roseuid 676799BF0069
    */
   public Client() 
   {
    
   }
   
   /**
    * @roseuid 676796D100A0
    */
   public void client() 
   {
    
   }

      public static void main(String[] args) {
         Eagle eagle = new Eagle();
         eagle.setFlyBehavior(new FlyBehavior() {
            @Override
            public void fly() {
               System.out.println("老鹰在天空中翱翔");
            }
         });

         eagle.setSwimBehavior(new UnableSwim());


         eagle.display();
         eagle.flyBehavior.fly();
         eagle.swimBehavior.swim();


         Penguin penguin = new Penguin();
         penguin.setFlyBehavior(new UnableFly()); // 企鹅不会飞
         penguin.setSwimBehavior(new AbleSwim()); // 企鹅会游泳

         penguin.display();
         penguin.flyBehavior.fly();
         penguin.swimBehavior.swim();
      }

}
